.content {
    overflow-y: auto;
    overflow-x: hidden;
    flex-wrap: nowrap;
    height: calc(100vh - #{$header-height});

    @include breakpoint-min(breakpoints(lg)) {
        display: flex;
    }
}

.content__main {
    flex: 1;
    min-width: 0;
    background-color: $content-bg;
    align-self: flex-start;
    padding: $content-padding;

    @include breakpoint-min(breakpoints(xl)) { 
        padding-left: $sidebar-width + $content-padding;
        transition: padding-left 300ms;
        will-change: padding-left;
    }
}

.sidebar-active {
    .content__main {
        padding-left: $content-padding;
    }
}

.content__aside {
    @include breakpoint-min(breakpoints(lg)) {
        flex-shrink: 0;
        position: sticky;
        top: 0;
        order: 2;
    }
}

.content__right {
    position: sticky;
    top: 0;
    overflow: scroll;
}

// Keep only the main content when the page is loaded inside an iframe.
// Currently we load certain pages inside iframes for PathFactory analytics.
.inside-iframe {
    .header,
    .sidebar {
        display: none;
    }

    .content {
        height: 100vh;
    }

    .content__main {
        padding-left: $content-padding;
    }
}